package com.ggb.reactive.extension

import org.slf4j.Logger
import org.slf4j.LoggerFactory

//不对变量进行内联会产生一个方法，如果内联了，那么就会直接复制粘贴
inline val <T : Any> T.log: Logger
    get() = LoggerFactory.getLogger(javaClass)
inline fun <reified T : Any> logger(): Logger = LoggerFactory.getLogger(T::class.java)

inline fun <reified T : Any> T.thisLogger(): Logger = LoggerFactory.getLogger(this::class.java)